/************************************************************************
 * <br>
 * <ul>
 * <li>版权所有：唐山弘川科技有限公司 2009－2020</li>
 * <li>创建日期：2009-8-12</li>
 * <li>初始作者：刘川</li>
 * </ul>
 * <ul>
 * <b>修订历史</b>
 * <li>1、</li>
 * </ul>
 ***********************************************************************/
package com.hy.erp.inventory.pojo ;

import javax.persistence.Column ;
import javax.persistence.Entity ;
import javax.persistence.FetchType ;
import javax.persistence.ManyToOne ;
import javax.persistence.OneToOne ;
import javax.persistence.PrimaryKeyJoinColumn ;
import javax.persistence.Table ;

import org.hibernate.annotations.Index ;
//import org.jboss.seam.annotations.Name ;

import com.hy.erp.inventory.dao.interfaces.IAreaDao;
import com.hy.erp.inventory.pojo.interfaces.IArea;
import com.hy.mydesktop.shared.persistence.domain.gxt.MyBaseModel;
//import com.hy.erp.inventory.vsoft.libra.enterprise.framework.persistence.api.annotation.DaoA;
//import com.hy.erp.inventory.vsoft.libra.enterprise.framework.persistence.entity.AbstractPersistentEntity;
/**
 * 
 * <ul>
 * <li>开发作者：李冰</li>
 * <li>设计日期：2010-10-5；时间：下午04:19:09</li>
 * <li>类型名称：Area</li>
 * <li>设计目的：区</li>
 * </ul>
 * <ul>
 * <b>修订编号：</b>
 * <li>修订日期：</li>
 * <li>修订作者：</li>
 * <li>修订原因：</li>
 * <li>修订内容：</li>
 * </ul>
 */
/*@Name("area")
@ Entity 
@Table(name="area")
@DaoA(IAreaDao.class)*/
public class Area extends MyBaseModel //implements IPositonType
//public class Area extends AbstractPersistentEntity implements IArea
{
	private static final long	serialVersionUID	=
	                                                  7782327554482110000L ;
	


	/**
	 * 构造函数
	 */
	public Area ( )
	{
		super ( ) ;
	}

	

	@ManyToOne(targetEntity=LocationType.class,fetch=FetchType.LAZY)
	@PrimaryKeyJoinColumn
	public LocationType getLocationType ( )
		{
			return this.get(IArea.LOCATIONTYPE) ;
		}

		public void setLocationType (
										LocationType locationType )
		{
			super.set ( IArea.LOCATIONTYPE , locationType );
		}
		
		
		@ Column ( name = "abbreviation" , length = 50)
		@ Index ( name = "abbreviationIndex" )
		public String getAbbreviation ( )
		{
			return this.get(IArea.ABBREVIATION) ;
		}

		public void setAbbreviation (
										String abbreviation )
		{
			super.set ( IArea.ABBREVIATION , abbreviation );
		}
		@ Column ( name = "ancillaryCode" , length = 50)
		@ Index ( name = "ancillaryCodeIndex" )
		public String getAncillaryCode ( )
		{
			return this.get(IArea.ANCILLARYCODE) ;
		}

		public void setAncillaryCode (
										String ancillaryCode )
		{
			super.set ( IArea.ANCILLARYCODE , ancillaryCode );
		}
		@ ManyToOne ( targetEntity = Postcode.class , fetch = FetchType.LAZY )
		public Postcode getAreaPostcode ( )
		{
			return this.get(IArea.AREA_POSTCODE) ;
		}

		public void setAreaPostcode (
										Postcode areaPostcode )
		{
			super.set ( IArea.AREA_POSTCODE , areaPostcode );
		}
		@ ManyToOne ( targetEntity = County.class , fetch = FetchType.LAZY )
		public County getCounty ( )
		{
			return this.get(IArea.COUNTY) ;
		}

		public void setCounty (
								County county )
		{
			super.set ( IArea.COUNTY , county );
		}
		@ Column ( name = "description" , length = 50)
		@ Index ( name = "descriptionIndex" )
		public String getDescription ( )
		{
			return this.get(IArea.DESCRIPTION) ;
		}

		public void setDescription (
										String description )
		{super.set ( IArea.DESCRIPTION , description );
		}
		@ Column ( name = "name" , length = 50)
		@ Index ( name = "nameIndex" )
		public String getName ( )
		{
			return this.get(IArea.NAME) ;
		}

		public void setName (
								String name )
		{
			super.set ( IArea.NAME , name );
		}
		@ Column ( name = "namedCode" , length = 50)
		@ Index ( name = "namedCodeIndex" )
		public String getNamedCode ( )
		{
			return this.get(IArea.NAMECODE) ;
		}

		public void setNamedCode (
									String namedCode )
		{
			super.set ( IArea.NAMECODE , namedCode );
		}


		
		
}
